package com.nulldev.util.web.nTube.util.demos;

import static com.nulldev.util.web.nTube.pages.Urlizer.decodeUrlizer;
import static com.nulldev.util.web.nTube.pages.Urlizer.urlizer;

import com.nulldev.util.JVM.JVM;
import com.nulldev.util.web.nTube.pages.Urlizer.UrlizerMethod;

public class UrlizerV3Demo {

	public static void main(String[] args) {
		{
			final String o = "http://127.0.0.1:8080/proxyAPI?uzc=rr3---sn-x2pm-3uf6.googlevideo.com/videoplayback&uzm=sr-ip-v2&mn=sn-x2pm-3uf6%2Csn-f5f7kn7z&mm=31%2C29&svpuc=1&expire=1683571699&ns=JP0ScJT9PZtkAHfEpVGjbY0N&c=WEB&mt=1683549904&initcwndbps=2425000&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&ms=au%2Crdu&n=R9kRQsgPO5awtQ&mv=m&cnr=14&mvi=3&ratebypass=yes&itag=18&ip=127.1.1.3&id=o-AJL-Uw1yGmw2VUHYMMQo0qJ7VAapSfz2zfax5BkwnSdF&fexp=24007246&vprv=1&txp=5438434&fvip=2&source=youtube&dur=256.023&ei=ku9YZJTSPMey1gL38rHwCg&pl=20&lsig=AG3C_xAwRQIgGxwL9j4lhTKksN1BjCKGQJCOJcE1TxpHBstWZohzU_4CIQDXNkV0uDhKGe_-M6wzKHX9uI602ZJoVvwp1GthYN3U-A%3D%3D&mh=F0&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Csvpuc%2Cmime%2Cns%2Ccnr%2Cratebypass%2Cdur%2Clmt&mime=video%2Fmp4&sig=AOq0QJ8wRgIhAOzFkCOZlfFfT79PLj9FbHb0YcQiCWZMX6B6TQ2TnNY2AiEA2IcalFcvypUyzPQJrWFLJo-b18OcALVAd_xAvPja5WE=&lmt=1666415077637081&requiressl=yes&uzs=1";
			JVM.println("raw (" + o.length() + "): " + o);
			final String s = urlizer(o, UrlizerMethod.SR_IP_V3_PROTO);
			JVM.println("urlizer (" + s.length() + "): " + s);
			final String f4 = decodeUrlizer(s);
			JVM.println("decode (" + f4.length() + "): " + f4);
		}
	}

}
